package com.example.multipledemo;

import android.app.Application;
import android.content.Context;
import android.support.multidex.MultiDex;

/**
 * Created by tangjiangxu on 11/9/17.
 */

public class MyApplication extends Application {
    Test test = new Test();

    @Override
    protected void attachBaseContext(Context base) {
        super.attachBaseContext(base);
        MultiDex.install(this);
        test.test();
    }

    @Override
    public void onCreate() {
        super.onCreate();
        //在这里为应用设置异常处理，然后程序才能获取未处理的异常
        MyCrashHandler crashHandler = MyCrashHandler.getInstance();
        crashHandler.init(this);
    }
}
